<div class="col-sm-12 mt20">

    <div class="panel panel-default">
        <div class="panel-body" ng-keyup="myKeyup($event)">
            <div class="col-sm-2">
                <input type="text" class="form-control" placeholder="名称" ng-model="searchform.address">
            </div>
            <div class="col-sm-2">
            </div>
            <div class="col-sm-2">
            </div>
            <div class="col-sm-2">
                <!-- <input type="text" class="form-control" placeholder="卡面号" ng-model="searchform.smart_card_no"> -->
            </div>
            <div class="col-sm-2">
                <button class="btn btn-success search btn-block" ng-click="create()" ng-if="!pageInfo.type">创建发车地点</button>
            </div>
            <div class="col-sm-2">
                <button class="btn btn-info search btn-block" ng-click="loadlist()">查询乘车情况</button>
            </div>
        </div>

        <div class="panel-body">
            <table class="table table-striped table-bordered dataTable table-condensed tree_table" style="table-layout:fixed">
                <thead>
                    <tr>
                        <th class="col-md-2 text-center">发车地点</th>
                        <th class="col-md-1 text-center">发车时间</th>
                        <th class="col-md-1 text-center">机构名称</th>
                        <th class="col-md-1 text-center">出游日期</th>
                        <th class="col-md-1 text-center">报名人数</th>
                        <th class="col-md-1 text-center" ng-if="!pageInfo.type">操作</th>
                    </tr>
                </thead>
                <tbody>
                    <tr ng-repeat="address in addressList">
                        <td class="text-center">{{address.address}}</td>
                        <td class="text-center">{{address.start_time}}</td>
                        <td class="text-center">{{address.company_name? address.company_name: '暂无报名机构'}}</td>
                        <td class="text-center">{{address.tour_date? address.tour_date: '暂无出游日期'}}</td>
                        <td class="text-center">{{address.num}}</td>
                        <td class="text-center" ng-if="!pageInfo.type">
                            <button type="button" class="btn btn-info btn-xs" ng-click="info(address)" ng-disabled="address.num">编辑</button>
                            <button type="button" class="btn btn-danger btn-xs" ng-click="delete(address)" ng-disabled="address.num">删除</button>
                        </td>
                    </tr>
                    <tr ng-if="addressList.length == 0">
                        <td colspan="4" class="text-center">
                            没有数据
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>

        <div class="text-right" style="background-color: white; margin-right: 30px">
            <pagination total-items="totalItems" ng-model="currentPage" ng-change="loadlist()" previous-text="上一页" next-text="下一页" first-text="首页"
                last-text="尾页" max-size="5" boundary-links="true" rotate="false" items-per-page="itemsPerPage" class="m-t-none m-b"></pagination>
        </div>

    </div>
</div>